<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
<script type="text/javascript">
	// var name1 = '张三';
	// var name2 = '李四';
	// var name3 = '王五';

	// var name = '张三王李四';

	// 隐型方式创建数组
	// var jingdian = ['长城','故宫','天坛','颐和园','香山'];
	// alert(jingdian[4]);

	// 用构造函数的方式创建数组
	// var jingdian = new Array('长城','故宫','天坛','颐和园','香山');
	// alert(jingdian[3])


	var jingdian = ['长城','故宫','天坛','颐和园','香山'];
	// alert(jingdian.length);
	// alert(jingdian[4])
	// jingdian[jingdian.length] = '水立方';
	// jingdian[jingdian.length] = '鸟巢';
	// alert(jingdian)
	jingdian[8] = '水立方';
	alert(jingdian.length);

</script>
</head>

<body>






</body>
</html>
